public class PlayerMoveState : PlayerGroundedState
{
    public PlayerMoveState(Player player, string animBoolName) : base(player, animBoolName) { }

    public override void Enter()
    {
        base.Enter();
        AudioManager.Instance.PlaySfx(14, null);
    }

    public override void Exit()
    {
        base.Exit();
        AudioManager.Instance.StopSfx(14);
    }

    public override void Update()
    {
        base.Update();

        if ((xInput == 0 && player.IsGroundDetected()) || player.IsWallDetected())
            StateMachine.ChangeState(player.IdleState);
        player.SetVelocity(xInput * player.moveSpeed, rb.velocity.y);
    }
}